﻿using System.Threading;

namespace Inovout.Security
{
    public static class AccountAuthentication
    {
        //private static readonly IUserService userService;
        //static AccountAuthentication()
        //{
        //    userService = ComponentManager.Resolve<IUserService>();

        //}
        //public static IUser GetUser(string userName)
        //{
        //  //  ArgumentGuard.IsNotNullOrEmptyString(userName, "userName");
        //    return null;
        //    //IUser user = SystemUser.GetUser(userId);
        //    //if (user == null)
        //    //{
        //    //    user = userService.Get(userId);
        //    //}
        //    //return user;
        //}
        //public static IUser GetAuthenticatedUser()
        //{
        //    if (Thread.CurrentPrincipal.Identity.IsAuthenticated)
        //    {
        //        return GetUser(Thread.CurrentPrincipal.Identity.Name);
        //    }
        //    else
        //    {
        //        return NotApplicableUser.Instance;
        //    }
        //}

        //public static UserPrincipal AnonymousUserPrincipal 
        //{
        //    get { return new UserPrincipal(new UserIdentity( WindowsUser.AnonymousUser)); }  
        //}

        //public static UserPrincipal GetPrincipal(string userName)
        //{
        //    return new UserPrincipal(new UserIdentity(null));
        //}
    }
}
